package com.ym.medical.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.ym.core.utils.tkmybatis.BaseSVImpl;

import com.ym.medical.dao.PositionListDao;
import com.ym.medical.domain.entity.PositionListEntity;
import com.ym.medical.service.IPositionListSV;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * ComputerName:LAPTOP-I6GKDIFQ
 * Author:admin
 * Date: 2019-06-12
 * Time: 15:53:48
 * 服务实现类
 */
@Service
@Transactional( rollbackFor = Exception.class)
public class PositionListSVImpl extends BaseSVImpl<PositionListEntity, PositionListDao> implements IPositionListSV {

    @Override
    public PageInfo<PositionListEntity> listPart(String type, Long id, int pageNo, int limit) {
        PageHelper.startPage(pageNo,limit);
        List<PositionListEntity> positionLists =  mapper.listPart(type,id);
        return new PageInfo<>(positionLists);
    }
}
